package com.polytech.beans;

import java.util.HashSet;
import java.util.Set;
import java.util.Vector;

import com.polytech.ihm.factory.FieldInformation;

public class Brand implements IDistance<Brand>{
	@FieldInformation(labelName="Nom de Marque")
	private String label;
	@FieldInformation(labelName="")
	private int value;
	private Set<Model>models=new HashSet<Model>();
	public Brand() {
	}
	public Brand(String label, int value) {
		super();
		this.label = label;
		this.value = value;
	}
	public String getLabel() {
		return label;
	}
	public void setLabel(String label) {
		this.label = label;
	}
	public int getValue() {
		return value;
	}
	public void setValue(int value) {
		this.value = value;
	}
	@Override
	public String toString() {
		return ""+label;
	}
	
	
	@Override
	public double distance(Brand value) {
		double val=Math.abs(this.value -value.getValue())*30;
		return val;
	}
	public Set<Model> getModels() {
		return models;
	}
	public void setModels(Set<Model> models) {
		this.models = models;
	}
	

}
